import com.videojukebox.application.AppController;
import com.zemoga.util.youtube.YoutubeSearchVideoProxy;

import flash.system.Security;

import mx.events.FlexEvent;

private var appController:AppController;
private var searchVideo:YoutubeSearchVideoProxy 

private function seachSample():void
{
	searchVideo = new YoutubeSearchVideoProxy();
	searchVideo.getVideos();
}

private function initializeHandler(event:FlexEvent):void
{
	
	Security.allowDomain("www.youtube.com");
	
	Security.loadPolicyFile("http://www.youtube.com/crossdomain.xml");
	Security.loadPolicyFile("http://gdata.youtube.com/crossdomain.xml");
	Security.loadPolicyFile("http://i2.ytimg.com/crossdomain.xml");
	Security.loadPolicyFile("http://video-stats.video.google.com/crossdomain.xml");
	
	Security.loadPolicyFile("http://s2.youtube.com/crossdomain.xml");
	Security.loadPolicyFile("http://s.ytimg.com/crossdomain.xml");
	Security.loadPolicyFile("http://i.ytimg.com/crossdomain.xml");
	
	
	appController = AppController.getInstance();
	
	appController.application = this;
	/**/
	//seachSample();
}